package com.slashmobility.finappsparty.view;

import com.slashmobility.finapps.ActivityIbex35DataChart;
import com.slashmobility.finappsparty.helper.DataModelHelper;

import android.content.Context;
import android.content.Intent;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Toast;

/**
 * Clase que centralizar los eventos de Click
 * @author josecortes
 *
 */

public class ValueLayoutListener implements OnClickListener {
	private Context context;
	private ValueLayout valueLayout;
	
	public ValueLayoutListener(Context context, ValueLayout valueLayout)
	{
		this.context=context;
		this.valueLayout=valueLayout;		
	}
	
	@Override
	public void onClick(View v) {
 
		ActivityIbex35DataChart ib35=new ActivityIbex35DataChart();
		ib35.setCodigo(valueLayout.getCodigo());
		ib35.setNombreAccion(valueLayout.getDescripcion());
		Intent i2=ib35.execute(context);
 
		context.startActivity(i2);
	}
}
